<?php 
	include "header.html";
	include "mensaje.php";
?>
<script type="text/javascript" src="framework/js/util.js"></script>
<script type="text/javascript" src="framework/js/DB.js"></script>
<!--link rel="stylesheet" type="text/css" href="css/jquery.dataTables.css"/-->
<script src="js/table/jquery.dataTables.min.js"></script>
 <link rel="stylesheet" href="css/themes/base/jquery.ui.accordion.css" />
<script src="js/jquery-ui/jquery.ui.datepicker.min.js"></script>
<script type="text/javascript" src="js/jquery-ui/jquery.ui.dialog.min.js"></script>  
<script>
var maquinas;
var estados;
var tipos;

$(document).ready(function(){
	jQuery.ajaxSetup({async:false});
	armaTablaMaquinas();
});
function cerrarPopUp(){
	cancelarPregunta();
}

function armaTablaMaquinas(){
	var ret;
	var params={};		
	items=load("maquina",params);

	var str="<table id='maquinas'><thead><th>Nombre</th><th>Opciones</th></thead><tbody>";
	for (x=0;x<items.rowCount;x++){
		var obj=items.rows[x];		
		str += "<tr><td>" + obj.descripcion + "</td><td><a href='editarMaquina.php?id=" + obj.id + "'>Editar</a> </td></tr>";
	}			
	str+="</tbody></table>";
	$("#containerMatriceria").html(str);
	ret=setTable("maquinas",0);
		
	return ret;
}



</script>
		<input type="hidden" id="idItemWork"/>
		<input type="hidden" id="idMatriceriaWork"/>
		<div id="dialogDiv"></div>
<?php 
	include "menuMatriceria.html";
	?>
	<div class="container_12">
		<div class="grid_10">
			<div class="box round first">
				<h2>Maquinas</h2>
				<div class="block">
					<div id="containerMatriceria"></div>
				</div>
			</div>
		</div>
	</div>
	<div id="dialogDiv"></div>
    <?php include "footer.html"?>